<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script text="text/javascript">
    /**
     * @param {number[]} nums
     * @return {number}
     */
    var findLengthOfLCIS = function(nums) {
        if(nums.length==0)
        {
            return 0;
        }
        var ans=1;
        var sum=0;
        var flag=nums[0];
        for(var i=1;i<nums.length;i++)
        {
            if(nums[i]>flag)
            {
                flag=nums[i];
                ans++;
            }else{
                flag=nums[i];
                sum=Math.max(ans,sum);
                ans=1;
            }
        }
        sum=Math.max(ans,sum);
        return sum;
    };
    var x=findLengthOfLCIS([1,3,5,7]);
    console.log(x);
    </script>
</body>
</html>